package com.gexiaobao.pigeon.app.model.bean

import android.os.Parcelable
import kotlinx.parcelize.Parcelize

/**
 * @Author      : hxw
 * @Date        : 2024/5/7 9:27
 * @Describe    :
 */
@Parcelize
class LoftAllInfoResponse(

    var loftMemberList: ArrayList<LoftMember> = arrayListOf(),
    var loftAgentList: ArrayList<LoftAgent> = arrayListOf(),
    var loftFeatherColorList: ArrayList<LoftFeatherColor> = arrayListOf(),
    var loftDeviceList: ArrayList<LoftDevice> = arrayListOf(),

    ) : Parcelable {

    /**
     * 数据是否为空
     */
    fun isEmptyMember() = loftMemberList == null || (loftMemberList as List<*>).isEmpty()
    fun isEmptyAgent() = loftAgentList == null || (loftAgentList as List<*>).isEmpty()
    fun isEmptyFeatherColor() = loftFeatherColorList == null || (loftFeatherColorList as List<*>).isEmpty()
    fun isEmptyDevice() = loftDeviceList == null || (loftDeviceList as List<*>).isEmpty()

    @Parcelize
    class LoftMember(

        var id: Int = 0,
        var userId: Int = 0,
        var name: String = "",
        var shedNo: String = "",
        var mobile: String = "",
        var address: String = "",
        var pigeonNum: Int = 0,

        ) : Parcelable

    @Parcelize
    class LoftAgent(

        var id: Int = 0,
        var name: String = "",
        var mobile: String = "",
        var address: String = "",
        var pigeonNum: Int = 0,

        ) : Parcelable

    @Parcelize
    class LoftFeatherColor(

        var id: Int = 0,
        var featherColor: String = "",
        var orgId: Int = 0

    ) : Parcelable

    @Parcelize
    class LoftDevice(

        var id: Int = 0,
        var orgId: Int = 0,
        var status: Int = 0,
        var imsi: String = "",

        ) : Parcelable

}